<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="s"  uri="/struts-tags"%>
<%@ taglib prefix="sx" uri="/struts-dojo-tags" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
	<head>
		<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=cn-gb">
		<link href="css/style.css" rel="stylesheet" type="text/css">
		  <s:head theme="xhtml"/>
  		  <sx:head parseContent="true"/>

		<title>修改 入库进货单明细</title>

		<script type="text/javascript">
			function buyInDetailAction() {
				var d = document.forms[0];
				d.action = "updateBuyInDetail";
				d.submit();
			}
		</script>
		<style type="text/css">
		.errorMessage {
			font-size: 12px;
			color: red;
		}
		</style>
	</head>

	<body>
		<center>
			<h2>
				修改 入库进货单明细
			</h2>
		</center>
		<center>

			<%  String sErrMsg = request.getParameter( "error" ) ;
				if ( sErrMsg == null ) sErrMsg = "";
				sErrMsg = new String( sErrMsg.getBytes("ISO-8859-1"), "UTF-8" );
			%>
			<font color="red"><%= sErrMsg %></font>

			<s:form method="post">

				<s:hidden name="buyInDetail.id"		  value="%{buyInDetail.id}"/>
				<s:hidden name="buyInDetail.buyInId"  value="%{buyInDetail.buyInId}"/>
				<s:hidden name="buyInDetail.goodId"   value="%{buyInDetail.goodId}"/>
				<!-- 以上3个 都不可以改 -->
				
				商品 ：<s:property value="%{buyInDetail.goodName}" /> <br/>

				<table>

					<tr>
						<td>
							<s:textfield label="单价" name="buyInDetail.price" />
						</td>
					</tr>
					<tr>
						<td>
							<s:textfield label="数量" name="buyInDetail.amount" />
						</td>
					</tr>
					<tr>
						<td>
							<s:textfield label="金额" name="buyInDetail.money" />
							<!-- 待处理 自动计算 -->
						</td>
					</tr>
					<tr align="center">
						<td colspan="2">
							<input type="button" value="保存" name="Save" onclick="buyInDetailAction();" />
							<input type="reset"  value="重置" name="Reset" />
							<input type="button" value="返回" name="Back" onclick="history.go(-1);" />
						</td>
					</tr>
				</table>
			</s:form>
		</center>
	</body>
</html>